/**
 * 
 */
package com.xpec.c4.service.module.datacenter.player.db;

import java.math.BigDecimal;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;

import com.xpec.c4.db.model.log.basic.BasicTransactionLogModel;

/**
 * 專門針對開分回分的 log
 * 
 * @author TW15010
 */
@Entity
@Table(name = "open_score")
@org.hibernate.annotations.Table(appliesTo = "open_score", indexes = {
		@org.hibernate.annotations.Index(name = "IDX_EVENT_DATE", columnNames = { "eventDate" }),
		@org.hibernate.annotations.Index(name = "IDX_EVENT_TIME", columnNames = { "eventTime" }),
		@org.hibernate.annotations.Index(name = "IDX_OPEN_ID", columnNames = { "subVenderId", "openId" }), })
public class OpenScoreLogModel extends BasicTransactionLogModel {
	private static final long serialVersionUID = 3836795575812138009L;

	/** account guid */
	private String accountId;

	/** player guid */
	private String playerId;

	/** open id */
	private String openId;

	/** player name */
	private String playerName;

	/** 遊戲id */
	private String gameId;

	/** 遊戲館id */
	private String gameHallId;

	/** 幣別 */
	private String coinType;

	/** 暫存錢包 異動數值 */
	private BigDecimal tmpChangeValue = BigDecimal.ZERO;

	/** 暫存錢包 異動前數值 */
	private BigDecimal tmpBeforeChange = BigDecimal.ZERO;

	/** 暫存錢包 變更後數值 */
	private BigDecimal tmpAfterChange = BigDecimal.ZERO;

	/** 金幣 異動數值 */
	private BigDecimal goldChangeValue = BigDecimal.ZERO;

	/** 金幣 異動前數值 */
	private BigDecimal goldBeforeChange = BigDecimal.ZERO;

	/** 金幣 變更後數值 */
	private BigDecimal goldAfterChange = BigDecimal.ZERO;

	/** 異動數值 */
	private BigDecimal totalChangeValue = BigDecimal.ZERO;

	/** 加總 異動前數值 gold + tmpCash */
	private BigDecimal totalBeforeChange = BigDecimal.ZERO;

	/** 加總 變更後數值 gold + tmpCash */
	private BigDecimal totalAfterChange = BigDecimal.ZERO;

	/** 行為id {@link OpenScoreChangeWay} */
	private int changeWay;

	/** 行為說明 */
	private String changeWayDesc;

	/** 營運商 id */
	private String venderId;

	/** 子營運商 id */
	private String subVenderId;

	public String getAccountId() {
		return accountId;
	}

	public void setAccountId(String accountId) {
		this.accountId = accountId;
	}

	public String getPlayerId() {
		return playerId;
	}

	public void setPlayerId(String playerId) {
		this.playerId = playerId;
	}

	public String getOpenId() {
		return openId;
	}

	public void setOpenId(String openId) {
		this.openId = openId;
	}

	public String getPlayerName() {
		return playerName;
	}

	public void setPlayerName(String playerName) {
		this.playerName = playerName;
	}

	public String getGameId() {
		return gameId;
	}

	public void setGameId(String gameId) {
		this.gameId = gameId;
	}

	public String getGameHallId() {
		return gameHallId;
	}

	public void setGameHallId(String gameHallId) {
		this.gameHallId = gameHallId;
	}

	public String getCoinType() {
		return coinType;
	}

	public void setCoinType(String coinType) {
		this.coinType = coinType;
	}

	@Column(precision = 19, scale = 2, columnDefinition = "DECIMAL(19,2) default 0.0")
	public BigDecimal getTmpChangeValue() {
		return tmpChangeValue;
	}

	public void setTmpChangeValue(BigDecimal tmpChangeValue) {
		this.tmpChangeValue = tmpChangeValue;
	}

	@Column(precision = 19, scale = 2, columnDefinition = "DECIMAL(19,2) default 0.0")
	public BigDecimal getTmpBeforeChange() {
		return tmpBeforeChange;
	}

	public void setTmpBeforeChange(BigDecimal tmpBeforeChange) {
		this.tmpBeforeChange = tmpBeforeChange;
	}

	@Column(precision = 19, scale = 2, columnDefinition = "DECIMAL(19,2) default 0.0")
	public BigDecimal getTmpAfterChange() {
		return tmpAfterChange;
	}

	public void setTmpAfterChange(BigDecimal tmpAfterChange) {
		this.tmpAfterChange = tmpAfterChange;
	}

	@Column(precision = 19, scale = 2, columnDefinition = "DECIMAL(19,2) default 0.0")
	public BigDecimal getGoldChangeValue() {
		return goldChangeValue;
	}

	public void setGoldChangeValue(BigDecimal goldChangeValue) {
		this.goldChangeValue = goldChangeValue;
	}

	@Column(precision = 19, scale = 2, columnDefinition = "DECIMAL(19,2) default 0.0")
	public BigDecimal getGoldBeforeChange() {
		return goldBeforeChange;
	}

	public void setGoldBeforeChange(BigDecimal goldBeforeChange) {
		this.goldBeforeChange = goldBeforeChange;
	}

	@Column(precision = 19, scale = 2, columnDefinition = "DECIMAL(19,2) default 0.0")
	public BigDecimal getGoldAfterChange() {
		return goldAfterChange;
	}

	public void setGoldAfterChange(BigDecimal goldAfterChange) {
		this.goldAfterChange = goldAfterChange;
	}

	public int getChangeWay() {
		return changeWay;
	}

	public void setChangeWay(int changeWay) {
		this.changeWay = changeWay;
	}

	public String getChangeWayDesc() {
		return changeWayDesc;
	}

	public void setChangeWayDesc(String changeWayDesc) {
		this.changeWayDesc = changeWayDesc;
	}

	@Column(columnDefinition = "VARCHAR(50) NOT NULL default 'TONWA'")
	public String getVenderId() {
		return venderId;
	}

	public void setVenderId(String venderId) {
		this.venderId = venderId;
	}

	@Column(columnDefinition = "VARCHAR(50) NOT NULL default 'TONWA'")
	public String getSubVenderId() {
		return subVenderId;
	}

	public void setSubVenderId(String subVenderId) {
		this.subVenderId = subVenderId;
	}

	@Column(precision = 19, scale = 2, columnDefinition = "DECIMAL(19,2) default 0.0")
	public BigDecimal getTotalChangeValue() {
		return totalChangeValue;
	}

	public void setTotalChangeValue(BigDecimal totalChangeValue) {
		this.totalChangeValue = totalChangeValue;
	}

	@Column(precision = 19, scale = 2, columnDefinition = "DECIMAL(19,2) default 0.0")
	public BigDecimal getTotalBeforeChange() {
		return totalBeforeChange;
	}

	public void setTotalBeforeChange(BigDecimal totalBeforeChange) {
		this.totalBeforeChange = totalBeforeChange;
	}

	@Column(precision = 19, scale = 2, columnDefinition = "DECIMAL(19,2) default 0.0")
	public BigDecimal getTotalAfterChange() {
		return totalAfterChange;
	}

	public void setTotalAfterChange(BigDecimal totalAfterChange) {
		this.totalAfterChange = totalAfterChange;
	}
}